package cn.xiongxf.dto;

import cn.xiongxf.domain.Course;
import cn.xiongxf.domain.CourseDetail;
import cn.xiongxf.domain.CourseMarket;
import cn.xiongxf.domain.CourseResource;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import java.util.List;

@Data
public class CourseAddDto {
    // 课程
    @Valid  //  对象加参数较验注解
    private Course course;

    // 课程详情
    @Valid
    private CourseDetail courseDetail;

    // 课程营销
    @Valid
    private CourseMarket courseMarket;

    // 课程资源
    @Valid
    private CourseResource courseResource;

    // 所有老师的id
    @NotNull(message = "请选择老师！")
    private List<Long> teacherIds;
}
